package com.neardrug.mapper;

import com.neardrug.entity.FormImg;
import com.neardrug.entity.FormTable;
import org.apache.ibatis.annotations.Delete;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Select;
import org.apache.ibatis.annotations.Update;

import java.util.List;

@Mapper
public interface FormTableMapper {


    public void insert(List<FormTable> formTableList);


    @Select("select * from tb_form_table where task_id=#{taskId}")
    List<FormTable> getByTaskId(Integer taskId);

    @Update("update tb_form_table set html=#{html} where id=#{id}")
    void updateHTML(Integer id, String html);

    @Delete("delete from tb_form_table where id=#{id}")
    Integer deleteHtmlById(Integer id);
}
